#include "mygraphicsview.h"
#include<QMouseEvent>
#include<QDebug>
#include<QScrollBar>
MyGraphicsView::MyGraphicsView(QWidget *parent) : QGraphicsView(parent)
{

}

void MyGraphicsView::mousePressEvent(QMouseEvent *event)
{
    emit mousePress(event);
    QGraphicsView::mousePressEvent(event);
}

void MyGraphicsView::mouseDoubleClickEvent(QMouseEvent *event)
{
    emit mouseDoubleClick(event);
    QGraphicsView::mouseDoubleClickEvent(event);
}

void MyGraphicsView::mouseMoveEvent(QMouseEvent *event)
{
    emit mouseMove(event);
    QGraphicsView::mouseMoveEvent(event);

}

void MyGraphicsView::keyPressEvent(QKeyEvent *event)
{
    emit keyPress(event);
    QGraphicsView::keyPressEvent(event);
}

void MyGraphicsView::mouseReleaseEvent(QMouseEvent *event)
{
    emit mouseRelease(event);
    QGraphicsView::mouseReleaseEvent(event);
}
